package com.github.rpc4j.consumer.cglib;

import java.lang.reflect.Method;

import org.objectweb.asm.Type;

import com.github.rpc4j.common.ServiceRequest;
import com.github.rpc4j.consumer.asm.ClassDump;

import net.sf.cglib.beans.BeanGenerator;

import junit.framework.TestCase;

public class DyClass extends TestCase{

	public void testInface() throws Exception{
		ServiceRequest request = new ServiceRequest();
		request.setInterfaceName("com.github.rpc4j.consumer.cglib.IUserService");
        request.setVersion("1.0");
		
		ClassDump<IUserService> dump = new ClassDump<IUserService>();
		
		/*IUserService service = dump.getObject(request);
		System.out.println(service.create("aa","bb"));
		
		service.get();*/
		
	
}
	
/*	public void testCglib() throws ClassNotFoundException{
		
		Class clzss = Class.forName("com.github.rpc4j.consumer.cglib.IUserService");
		
		BeanGenerator generator = new BeanGenerator();
		
		generator.setSuperclass(DyClass.class);
		
		Object object = generator.create();
		
		System.out.println(object);
		
	}*/

}
